obj-m := ds18b20.o
KERNELDIR ?=/home/pikaqiu/minefl2440/kernel/linux-3.0_song
PWD := $(shell pwd)
CC := /opt/buildroot-2012.08/arm920t/usr/bin/arm-linux-gcc
CLEAN := rm -rf

all : ds18b20.c ds18_test
	    $(MAKE) -C $(KERNELDIR) M=$(PWD) modules
ds18b20 : ds18b20.c
	    $(CC) ds18_test.c -o ds18_test
clobber :
	    $(CLEAN) ds18_test ds18b20.ko
clean :
	    $(CLEAN) *.mod.* *.o *~ modules.order Module.symvers
